import request from '@/utile/request.js'
import store from '@/store/index.js'
const getHomeChannelAPI = () => {
  return request({
    url: '/v1_0/user/channels',
    headers: {
      Authorization: 'Bearer ' + store.state.token
    }
  })
}
const getArticleListAPI = ({ channel_id, timestamp }) => {
  return request({
    url: '/v1_0/articles',
    params: { channel_id, timestamp: timestamp || Date.now() }
  })
}
export { getHomeChannelAPI, getArticleListAPI }
